<template>
  <div>
    <div class="com-top-nav">
      <van-nav-bar
        left-arrow
        @click-left="onClickLeft"
        :title="title"
      />
    </div>
    <div>
      <task-list-item link="/home/taskDetail" :type="type"></task-list-item>
    </div>
  </div>
</template>
<script>
  import Vue from 'vue';
  import taskListItem from '../../components/task-list-item';
  import {NavBar, Swipe, SwipeItem, Row, Col, Icon,} from 'vant';

  Vue.use(NavBar)
  Vue.use(Swipe)
  Vue.use(SwipeItem);
  Vue.use(Row)
  Vue.use(Col)
  Vue.use(Icon);
  export default {
    props: ['type'],
    data(){
      return {
        title: '任务列表',
      }
    },
    components: {
      Swipe, SwipeItem, Row, Col, Icon, taskListItem
    },
    methods: {
      onClickLeft() {
        this.$router.history.go(-1);
      }
    }
  }
</script>

<style scoped lang="less" type="text/less">
  @import url('../../../static/style/bottom-person-nav.less');

  .demo-color-btn {
    margin: 8px;
  }
  .user {
    &-poster {
      width: 7.5rem;
      height: 4rem;
      display: block;
    }
    &
    -group {
      margin-bottom: .3rem;
    }

    &
    -links {
      padding: 15px 0;
      font-size: 12px;
      text-align: center;
      background-color: #fff;

      .van-icon {
        display: block;
        font-size: 24px;
      }

    }
  }
</style>
